#ifndef WIDGETLIST_H
#define WIDGETLIST_H

#include "Widget.h"
#include <vector>


class WidgetList : public Widget
{
    public:
        WidgetList(int,int,int,int,int);
        virtual void onRender(sf::RenderWindow*);
        virtual void onEvent(sf::Event*);
        void select(int);
        void scroll(int);
        void updateGfx();
        void add(std::string);
        void clear();
        std::string* getSelected();
        virtual ~WidgetList();
    protected:
        int textSize;
        int w, h;
        sf::RectangleShape box;
        std::vector<std::string> text;
        int selector;
        sf::Text* graphicalText;
        sf::RectangleShape selection;
        int offset;
};

#endif // WIDGETLIST_H
